const service = require("../service/jobService")

const controller = {
    findList(req, res) {
        const { pageNum, limit } = req.query
        service.findList(pageNum, limit, (data) => {
            res.send({
                status: data ? data[0].length ? 200 : 400 : 500,
                pageNum: pageNum,
                pageAll: data && data[1][0].Allnum,
                data: data ? data[0] : "查询失败"
            })
        })
    }
}

module.exports = controller